////////////////////////////////////////////////////////////////////////////////
/// Midnight Circus 2007
////////////////////////////////////////////////////////////////////////////////

namespace GatherTogether
{
    namespace GatherDropRates
    {
        /// <summary>
        /// Class that contains information about item drop rates from different areas.
        /// </summary>
        class GatherDropRatesDB // : System.Collections.Generic.IEnumerable<Node>
        {
            protected Continent[] m_continents = new Continent[GatherConstants.NumberOfContinents];

            public GatherDropRatesDB()
            {
                // Initialize the array
                for (int i = 0; i < m_continents.Length; ++i)
                {
                    m_continents[i] = new Continent();
                }
            }

            public Continent this[int index]
            {
                get
                {
                    return m_continents[index];
                }
                set
                {
                    m_continents[index] = value;
                }
            }

            public void Merge(GatherDropRatesDB otherDropRates)
            {
                for (int index = 0; index < m_continents.Length; ++index)
                {
                    m_continents[index].Merge(otherDropRates[index]);
                }
            }
        }
    }
}
